import { createHashRouter, Navigate } from "react-router-dom";
import Home from "@/pages/美团案例/index.tsx";
import AuthRoute from "@/components/AuthRoute";

const router = createHashRouter([
  {
    path: "/",
    element: <Navigate to="/home" replace />,
  },
  {
    path: "/home",
    element: (
      <AuthRoute>
        <Home />
      </AuthRoute>
    ),
  },
  {
    path: "*",
    element: <div>404</div>,
  },
]);

export default router;
